using System.Windows.Media;

namespace MDSAdministration
{
    public class CompareData
    {
        public Brush BrushNull { get; set; }
        public SolidColorBrush BrushDifferent { get; set; }
        public SolidColorBrush BrushSame { get; set; }

        public string Col1 { get; set; }

        public Brush Col1Colour
        {
            get
            {
                switch (Status)
                {
                    case objectStatus.BoothNull:
                        return BrushNull;
                    case objectStatus.Col1Null:
                        return BrushNull;
                    case objectStatus.Col2Null:
                        return BrushDifferent;
                    case objectStatus.Different:
                        return BrushDifferent;
                    default:
                        return BrushSame;

                }
            }
        }
        public string Col2 { get; set; }
        public Brush Col2Colour
        {
            get
            {
                switch (Status)
                {
                    case objectStatus.BoothNull:
                        return BrushNull;
                    case objectStatus.Col1Null:
                        return BrushDifferent;
                    case objectStatus.Col2Null:
                        return BrushNull;
                    case objectStatus.Different:
                        return BrushDifferent;
                    default:
                        return BrushSame;

                }
            }
        }
        public enum objectStatus
        {
            BoothNull,
            Col1Null,
            Col2Null,
            Different,
            Same
        }

        public objectStatus Status
        {
            get
            {
                if (Col1 == null & Col2 == null)
                {
                    return objectStatus.BoothNull;
                }
                if (Col1 == null)
                {
                    return objectStatus.Col1Null;
                }
                if (Col2 == null)
                {
                    return objectStatus.Col2Null;
                }
                if (Col1 != Col2)
                {
                    return objectStatus.Different;
                }

                return objectStatus.Same;

            }
        }
    }
}